<template>
  <router-view />
</template>

<script>
import { defineComponent } from "@vue/runtime-core";
import { useRouter } from "vue-router";

export default defineComponent({
  setup() {
    const router = useRouter();

    router.beforeEach((to, from, next) => {
      console.log(to, from);
      next();
    });
  },
});
</script>

<style lang="less">
html, body {
  padding: 0;
  margin: 0;
}
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
}
</style>
